import java.util.Scanner;

public class ArrayExercise03 {
    public static void main(String[] args) {
        int[] Arr = new int[5];
        Scanner myScanner = new Scanner(System.in);
        int Max = Arr[0];
        int MaxIndex = 0;
        for (int i = 0;i < Arr.length;i++) {
            Arr[i] = myScanner.nextInt();
            if (Max < Arr[i]) {
                Max = Arr[i];
                MaxIndex = i;
            }
        }
        System.out.println("max="+Max+" "+"maxIndex="+MaxIndex);
    }
}

